/**
 * 文件表格列
 */
import { ref, h } from 'vue'
import { user } from '../../../entity/system/user'
import { TableColumnProps } from '../../../components/base/table/table-props'
import { LoginLog } from '../../../entity/system/login-log'
import { FileVo } from '../../../entity/system/file'

// @ts-ignore
export const columns: Array<TableColumnProps> = [
  {
    title: '编号',
    // @ts-ignore
    customRender: ({ index }) => index + 1,
    width: 60,
    align: 'center',
  },
  {
    title: '文件名',
    dataIndex: 'fileName',
    width: 250,
  },
  {
    title: '文件地址',
    dataIndex: 'fileUrl',
    ellipsis: true,
    width: 280,
  },
  {
    title: '创建时间',
    dataIndex: 'createTime',
    customRender: ({ record }) => (record.createTime ? record.createTime.replace('T', ' ') : ''),
    width: 200,
  },
  {
    title: '绝对路径',
    dataIndex: 'description',
    width: 500,
  },
  {
    title: '操作',
    dataIndex: 'action',
    width: 200,
    align: 'center',
    fixed: 'right',
  },
]
